# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Maintainer: Charles Mauch <cmauch@gmail.com>

pkgname=perl-datetime-format-ical
pkgver=0.09
pkgrel=13
pkgdesc="Perl/CPAN Module DateTime::Format::ICal"
arch=("any")
url="https://search.cpan.org/dist/DateTime-Format-ICal"
license=("GPL" "PerlArtistic")
depends=("perl-datetime-timezone" "perl-datetime-event-ical" "perl-datetime" "perl-params-validate" "perl-datetime-set")
makedepends=(perl-module-build)
source=("https://search.cpan.org/CPAN/authors/id/D/DR/DROLSKY/DateTime-Format-ICal-$pkgver.tar.gz")
sha256sums=('8b09f6539f5e9c0df0e6135031699ed4ef9eef8165fc80aefeecc817ef997c33')

build() {
  cd "$srcdir"/DateTime-Format-ICal-$pkgver

  unset PERL5LIB PERL_MM_OPT PERL_MB_OPT PERL_LOCAL_LIB_ROOT
  export PERL_MM_USE_DEFAULT=1 MODULEBUILDRC=/dev/null
  /usr/bin/perl Build.PL
  ./Build
}

package() {
  cd "$srcdir"/DateTime-Format-ICal-$pkgver
  unset PERL5LIB PERL_MM_OPT PERL_MB_OPT PERL_LOCAL_LIB_ROOT
  ./Build install --installdirs=vendor --destdir="$pkgdir"
}
